home *** CD-ROM | disk | FTP | other *** search
/ The Games Machine 76 / XENIATGM66.iso / Indiana Jones / Indiana Jones.exe / RESOURCE / PREVIEW.GOB / cog_pru_keypickup.cog < prev    next >
Text File  |  1999-11-15  |  908b  |  52 lines

  1. # Jones 3D Cog Script
  2. #
  3. # PRU_keyPickup.cog    
  4. #
  5. # [GGJ]
  6. #
  7. # (C) 1998 LucasArts Entertainment Company LLC. All Rights Reserved
  8. #
  9. # ========================================================================================
  10. symbols
  11. message entered
  12. message    startup
  13. message    taken
  14.  
  15. sector    keySector
  16. surface    outerFace
  17.  
  18. thing    keyGhost
  19. thing    keyCam
  20. thing    key
  21.  
  22. int        curCam    local
  23. int        in=0    local
  24.  
  25. end
  26. # ========================================================================================
  27. code
  28. startup:
  29. SetThingLight(key, '1.0 1.0 1.0', 0.01, 0.1);
  30. return;
  31. entered:
  32. if ((GetSenderRef() == keySector) && (in == 0))
  33. {
  34.     in = 1;
  35.     curCam = GetCurrentCamera();
  36.     SetCameraFocus(2, keyCam);
  37.     SetCameraSecondaryFocus(2, keyGhost);
  38.     SetCurrentCamera(2);
  39.     SetCameraFOV(110, 0, 0.0);
  40. }
  41. return;
  42.  
  43. taken:
  44. if (GetSenderRef() == key)
  45. {
  46.     setCurrentCamera(curCam);
  47. }
  48. return;
  49.  
  50. end
  51.  
  52.